package cn.itcast.goods.feign;

import cn.itcast.goods.pojo.Dish;
import cn.itcast.goods.vo.SetmealVO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

@FeignClient(value = "goods-service")
public interface GoodsClient {

    /**
     * 根据id查询菜品信息
     * @param id
     * @return
     */
    @GetMapping("/user/dish/getById/{id}")
    Dish getDishById(@PathVariable Long id);

    /**
     * 根据id查询套餐
     * @param id
     * @return
     */
    @GetMapping("/user/setmeal/{id}")
    SetmealVO getSetmealVOById(@PathVariable Long id);
}
